package org.example;

import org.apache.ibatis.annotations.Param;
import org.example.domain.Exam;
import org.example.domain.Student;
import org.example.domain.Student_Exam;
import org.example.dto.ExamPaperDTO;
import org.example.dto.ExamStudentDTO;
import org.example.vo.ExamBindClassVO;
import org.example.vo.PageVO;

import java.util.List;
import java.util.Map;

public interface ExamService {
    PageVO queryExam(int page,int count,Map<String,Object> map);
    boolean addSave(Exam exam);
    Exam selectExamById(Long id);
    boolean updateExamName(Long id,String name);
    void editSave(Exam exam,Map<String,String> studentCodeCache);
    void add(List<Student_Exam> student_examList);
    void remove(List<Student_Exam> student_examList);
    List<ExamBindClassVO> selectBindClassByExamId(Long examId);
    void removeExamByExamId(Long examId);
    void releaseExam(Long examId);
    void updateExamStatus(Long examId,String examStatus);

    /**
     *
     * @param param studentId  filterCondition 用于查找 当天  本周 本月的考试  分别为 1 2 3
     * @return
     */
    List<Map<String,String>> selectExamByStudentId(Map<String,Object> param);
    List<ExamPaperDTO> selectFinishExamClass(Long examId);
    List<ExamStudentDTO> selectExamStudentList(Long examId,String className);
    void handleOneStudentExamPaperScore(Student_Exam student_exam);
    ExamStudentDTO selectOneExamStudent(Long examId,Long studentId);
    void examPaperSubmit(Long examId);
    List<Integer> selectStudentCurrYear(Long studentId);
    List<ExamPaperDTO> selectExamByYear(@Param("studentId") Long studentId,@Param("year") Integer year);
}
